package com.fz.entity;

import lombok.Data;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.springframework.stereotype.Component;

import java.awt.print.Book;

/**
 * Created by webrx on 2017-09-08.
 */
@Data @Component
public class User {
    private String name;
    public void close(){
        System.out.println("destroy-method");
    }

    public void ok(){
        System.out.println("ok");
    }

    public void init() {
        System.out.println("初始化方法");
    }

    public User() {
        System.out.println("无参构造方法");
    }

    public User(String name) {
        this.name = name;
        System.out.println("String name()构造方法");
    }

    public void save(){
        System.out.println("数据库保存");
    }

    public void addUser(){
        System.out.println("数据库保存用户");
    }

    public void saveBook(){
        System.out.println("数据库保存书籍");
    }

    public void read(){
        System.out.println("数据读取");
    }
}
